summaryrefslogtreecommitdiff
path: root/app/[lng]/evcp/(evcp)/menu-list/page.tsx
diff options
context:
space:
mode:
authordujinkim <dujin.kim@dtsolution.co.kr>2025-08-21 06:57:36 +0000
committerdujinkim <dujin.kim@dtsolution.co.kr>2025-08-21 06:57:36 +0000
commit02b1cf005cf3e1df64183d20ba42930eb2767a9f (patch)
treee932c54d5260b0e6fda2b46be2a6ba1c3ee30434 /app/[lng]/evcp/(evcp)/menu-list/page.tsx
parentd78378ecd7ceede1429359f8058c7a99ac34b1b7 (diff)
(대표님, 최겸) 설계메뉴추가, 작업사항 업데이트
설계메뉴 - 문서관리 설계메뉴 - 벤더 데이터 gtc 메뉴 업데이트 정보시스템 - 메뉴리스트 및 정보 업데이트 파일 라우트 업데이트 엑셀임포트 개선 기본계약 개선 벤더 가입과정 변경 및 개선 벤더 기본정보 - pq 돌체 오류 수정 및 개선 벤더 로그인 과정 이메일 오류 수정
Diffstat (limited to 'app/[lng]/evcp/(evcp)/menu-list/page.tsx')
-rw-r--r--app/[lng]/evcp/(evcp)/menu-list/page.tsx22
1 files changed, 20 insertions, 2 deletions
diff --git a/app/[lng]/evcp/(evcp)/menu-list/page.tsx b/app/[lng]/evcp/(evcp)/menu-list/page.tsx
index 6645127f..5a1f71a5 100644
--- a/app/[lng]/evcp/(evcp)/menu-list/page.tsx
+++ b/app/[lng]/evcp/(evcp)/menu-list/page.tsx
@@ -10,13 +10,31 @@ import { MenuListTable } from "@/lib/menu-list/table/menu-list-table";
import { Shell } from "@/components/shell"
import * as React from "react"
import { InformationButton } from "@/components/information/information-button";
-export default async function MenuListPage() {
+import { useTranslation } from "@/i18n";
+interface MenuListPageProps {
+ params: Promise<{ lng: string }>
+}
+
+export default async function MenuListPage({ params }: MenuListPageProps) {
+ const { lng } = await params
+ const { t } = await useTranslation(lng, 'menu')
+
// 초기 데이터 로드
const [menusResult, usersResult] = await Promise.all([
getMenuAssignments(),
getActiveUsers()
]);
+ // 서버사이드에서 번역된 메뉴 데이터 생성
+ const translatedMenus = menusResult.data?.map(menu => ({
+ ...menu,
+ sectionTitle: menu.sectionTitle || "",
+ translatedMenuTitle: t(menu.menuTitle || ""),
+ translatedSectionTitle: t(menu.sectionTitle || ""),
+ translatedMenuGroup: menu.menuGroup ? t(menu.menuGroup) : null,
+ translatedMenuDescription: menu.menuDescription ? t(menu.menuDescription) : null
+ })) || [];
+
return (
<Shell className="gap-2">
<div className="flex items-center justify-between space-y-2">
@@ -60,7 +78,7 @@ export default async function MenuListPage() {
<CardContent>
<Suspense fallback={<div className="text-center py-8">로딩 중...</div>}>
<MenuListTable
- initialMenus={menusResult.data || []}
+ initialMenus={translatedMenus}
initialUsers={usersResult.data || []}
/>
</Suspense>